/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package edu.ucuenca.ec.nosql.modelos;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.HashSet;
import java.util.List;
import java.util.Set;

/**
 *
 * @author mivkys
 */
public class Category implements Serializable{
    private List<String> subCategory ;

    public Category() {
        subCategory = new ArrayList<>();
    }

    public Category(List<String> ranks) {
        this.subCategory = ranks;
    }

    /**
     * @return the subCategory
     */
    public List<String> getSubCategory() {
        return subCategory;
    }
    public String getSubcategorias(){
        String string = "";
        for (String subCategory1 : subCategory) {
            string+=subCategory1+" ";
        }
        return string;
    }
    public void setSubcategorias(String string){
    
    }
    /**
     * @param subCategory the subCategory to set
     */
    public void setSubCategory(List<String> subCategory) {
        this.subCategory = subCategory;
    }
    
    public int getTotal_Ranks() {
        return (subCategory!=null) ? subCategory.size():0;
    }
    public Set<String> subCategoriasSet(){
        Set<String> alphaSet = new HashSet<String>(subCategory);
        return alphaSet;
    }
}
